#include "afxcmn.h"
#if !defined(AFX_DLGIMAGEASS_H__9DD6D66F_2109_4FAD_8677_B5553FC7A946__INCLUDED_)
#define AFX_DLGIMAGEASS_H__9DD6D66F_2109_4FAD_8677_B5553FC7A946__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// DlgImageAss.h : header file
//

/////////////////////////////////////////////////////////////////////////////
// CDlgImageAss dialog
#include "BugDescriptDlg1.h"
#include "BugDescriptDlg2.h"
#include "BugDescriptDlg3.h"
#include "ScrollDlg.h"
#include "DlgHistogram.h"
#include "afxwin.h"

#include "DDLoadFileList.h"

#include "StandardFile.h"


class CDlgImageAss : public CScrollDlg, public StandardFile
{
// Construction
public:
	CDlgImageAss(CWnd* pParent = NULL);   // standard constructor
    ~CDlgImageAss();

// Dialog Data
	//{{AFX_DATA(CDlgImageAss)
	enum { IDD = IDD_TOOL_IMAGEASS };
		// NOTE: the ClassWizard will add data members here
	//}}AFX_DATA

public:
	void LoadFinished();
	BOOL m_bInit;

public:
	DlgHistogram *m_pStaticHis;
	void LoadHistogram(int nShow);

public:
	void LoadInitImage();

public:
	void ConfirmBugItem();
	void DeleteBugItem();

	void UpdateBugList();
	void UpdateNewBugItem();

public:
	void EnableAssButton(BOOL bEnable = TRUE);
	BOOL m_bAssEnable;


public:
	void ReLoadStanardFile();

private:
	//static int CALLBACK CB_OnLoadFileListFun(char *pFileName,zkImgFileTail *pFileTail,DWORD dwContext,void *pContext);
	//int OnLoadFileListFun(char *pFileName,zkImgFileTail *pFileTail,DWORD dwContext);

public:
	//void  LoadParentDir(char *pParentDir);
	//void  LoadFileList(char *pFileDir);
	//char m_szParentDir[MAX_PATH];
	//char m_szFolder1[100];
	//char m_szFolder2[100];
	char m_szMainDir[MAX_PATH];
	char m_szSubDir[MAX_PATH];
	char m_szFileName[MAX_PATH];

	//DDLoadFileList m_xLoadFileList;


    //void  LoadFile();


private:
	CBugDescriptDlg1 m_BugDescript1;
	CBugDescriptDlg2 m_BugDescript2;
	CBugDescriptDlg3 m_BugDescript3;

	int m_nBugCfg;

private:
	HWND m_hMeasureBut[3];
	HWND m_hTab;

public:
	char m_sImgAssDesc[4096];

public:
	static char m_sTabText[Bug_Cfg_MaxCount][64];

	char m_sBugCount[Bug_Cfg_MaxCount][512];
	int   m_nItemsCount[Bug_Cfg_MaxCount];
	float m_fItemsMaxValue[Bug_Cfg_MaxCount];
	float m_fItemsValues[Bug_Cfg_MaxCount];


// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CDlgImageAss)
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support
	//}}AFX_VIRTUAL

// Implementation
protected:

	// Generated message map functions
	//{{AFX_MSG(CDlgImageAss)
		// NOTE: the ClassWizard will add member functions here
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()

public:
	CTabCtrl  m_Tab;
	CComboBox m_ComboxAssLevel;
	CComboBox m_ComboxAssResult;
	CComboBox m_ComboxMainDir;
	CListCtrl m_ListImgFile;

public:
	virtual BOOL OnInitDialog();
	afx_msg void OnBnClickedButStaticautoadjust2();
	afx_msg HBRUSH OnCtlColor(CDC* pDC, CWnd* pWnd, UINT nCtlColor);	
	afx_msg void OnTcnSelchangeTab(NMHDR *pNMHDR, LRESULT *pResult);
	afx_msg void OnBnClickedButReverse();
	afx_msg void OnBnClickedButGradsdark();
	afx_msg void OnBnClickedButRilievo();
	afx_msg void OnBnClickedButEqual();
	afx_msg void OnBnClickedButStrengthen();
	afx_msg void OnBnClickedButMedian();
	afx_msg void OnBnClickedButLength();
	afx_msg void OnBnClickedButRectarea();
	afx_msg void OnBnClickedButEllipsearea();
	virtual BOOL DestroyWindow();
	afx_msg void OnTcnFocusChangeTab(NMHDR *pNMHDR, LRESULT *pResult);
	afx_msg void OnNMClickTab(NMHDR *pNMHDR, LRESULT *pResult);
	virtual BOOL PreTranslateMessage(MSG* pMsg);
	afx_msg void OnBnClickedButSaveassresult();
	afx_msg void OnBnClickedButLastassimage();
	afx_msg void OnBnClickedButNextassimage();
	afx_msg void OnBnClickedButOpen();
	afx_msg void OnCbnSelchangeComboboxexMaindir();
	afx_msg void OnNMDblclkListImagefile(NMHDR *pNMHDR, LRESULT *pResult);
};

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_DLGIMAGEASS_H__9DD6D66F_2109_4FAD_8677_B5553FC7A946__INCLUDED_)
